import http from '../utils/http'

// 创建订单
export const reqCreateOrder = (orderData) => {
  return http.post('/order/auth/trade', orderData)
}

// 获取订单列表
export const reqOrderList = (params) => {
  return http.get('/order/auth/list', params)
}

// 获取订单详情
export const reqOrderDetail = (orderId) => {
  return http.get(`/order/auth/${orderId}`)
}

// 取消订单
export const reqCancelOrder = (orderId) => {
  return http.get(`/order/auth/cancelOrder/${orderId}`)
}

// 删除订单
export const reqDeleteOrder = (orderId) => {
  return http.delete(`/order/auth/removeOrder/${orderId}`)
}

// 确认收货
export const reqConfirmReceive = (orderId) => {
  return http.get(`/order/auth/confirmReceive/${orderId}`)
}

// 获取订单支付信息
export const reqOrderPayInfo = (orderId) => {
  return http.get(`/order/auth/getPayInfo/${orderId}`)
}

// 获取订单物流信息
export const reqOrderLogistics = (orderId) => {
  return http.get(`/order/auth/getLogistics/${orderId}`)
} 